<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>用户登录 - ShoppingEase</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link href="https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css" rel="stylesheet">
    <link href="css/style.css" rel="stylesheet">
    <script>
        tailwind.config = {
            theme: {
                extend: {
                    colors: {
                        primary: '#165DFF',
                        secondary: '#FF7D00',
                        success: '#00B42A',
                        warning: '#FF7D00',
                        danger: '#F53F3F',
                        dark: '#1D2129',
                        'dark-2': '#4E5969',
                        'light-1': '#F2F3F5',
                        'light-2': '#E5E6EB',
                        'light-3': '#C9CDD4'
                    },
                    fontFamily: {
                        inter: ['Inter', 'system-ui', 'sans-serif'],
                    },
                }
            }
        }
    </script>
</head>
<body class="font-inter bg-gray-50 text-dark">
    <!-- 顶部通知栏 -->
    <div class="bg-primary text-white text-center py-1 px-4 text-sm">
        <p>全场满199元免运费 | 新用户注册立减50元 <a href="register.html" class="underline font-medium">立即注册</a></p>
    </div>

    <!-- 导航栏 -->
    <header class="sticky top-0 z-50 bg-white shadow-sm">
        <div class="container mx-auto px-4">
            <div class="flex items-center justify-between h-16 md:h-20">
                <!-- Logo -->
                <a href="index.html" class="flex items-center space-x-2">
                    <i class="fa fa-shopping-bag text-primary text-2xl"></i>
                    <span class="text-xl font-bold text-primary">ShoppingEase</span>
                </a>

                <!-- 搜索栏 - 中等屏幕以上显示 -->
                <div class="hidden md:flex items-center flex-1 max-w-xl mx-8">
                    <div class="relative w-full">
                        <input type="text" placeholder="搜索商品、品牌或分类..." 
                            class="w-full py-2 pl-10 pr-4 rounded-full border border-light-2 focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary transition-all">
                        <button class="absolute left-3 top-1/2 transform -translate-y-1/2 text-light-3 hover:text-primary transition-colors">
                            <i class="fa fa-search"></i>
                        </button>
                        <button class="absolute right-2 top-1/2 transform -translate-y-1/2 bg-primary text-white py-1 px-4 rounded-full hover:bg-primary/90 transition-colors">
                            搜索
                        </button>
                    </div>
                </div>

                <!-- 用户操作区 -->
                <div class="flex items-center space-x-4">
                    <!-- 搜索按钮 - 小屏幕显示 -->
                    <button class="md:hidden text-dark-2 hover:text-primary transition-colors">
                        <i class="fa fa-search text-xl"></i>
                    </button>
                    
                    <!-- 购物车 -->
                    <a href="cart.html" class="relative text-dark-2 hover:text-primary transition-colors">
                        <i class="fa fa-shopping-cart text-xl"></i>
                        <span id="cart-count" class="absolute -top-2 -right-2 bg-secondary text-white text-xs rounded-full h-5 w-5 flex items-center justify-center">0</span>
                    </a>
                    
                    <!-- 用户菜单 -->
                    <div class="relative">
                        <a href="login.html" class="flex items-center space-x-2 text-dark-2 hover:text-primary transition-colors">
                            <i class="fa fa-user-circle-o text-xl"></i>
                            <span class="hidden md:inline">登录/注册</span>
                        </a>
                    </div>
                </div>
            </div>

            <!-- 移动端搜索框 - 默认隐藏 -->
            <div class="py-3 hidden">
                <div class="relative w-full">
                    <input type="text" placeholder="搜索商品、品牌或分类..." 
                        class="w-full py-2 pl-10 pr-4 rounded-full border border-light-2 focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary transition-all">
                    <button class="absolute left-3 top-1/2 transform -translate-y-1/2 text-light-3 hover:text-primary transition-colors">
                        <i class="fa fa-search"></i>
                    </button>
                    <button class="absolute right-2 top-1/2 transform -translate-y-1/2 bg-primary text-white py-1 px-4 rounded-full hover:bg-primary/90 transition-colors">
                        搜索
                    </button>
                </div>
            </div>
        </div>
    </header>

    <main class="py-8">
        <div class="container mx-auto px-4">
            <div class="max-w-md mx-auto bg-white rounded-lg shadow-sm p-6 md:p-8">
                <h2 class="text-2xl font-bold mb-6 text-center">用户登录</h2>
                <form id="login-form">
                    <div class="mb-4">
                        <label for="username" class="block text-sm font-medium mb-1">用户名/手机号</label>
                        <input type="text" id="username" class="w-full px-3 py-2 border border-light-2 rounded focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary transition-all" placeholder="请输入用户名或手机号">
                    </div>
                    <div class="mb-6">
                        <label for="password" class="block text-sm font-medium mb-1">密码</label>
                        <input type="password" id="password" class="w-full px-3 py-2 border border-light-2 rounded focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary transition-all" placeholder="请输入密码">
                    </div>
                    <div class="flex items-center justify-between mb-6">
                        <label class="flex items-center">
                            <input type="checkbox" class="form-checkbox h-4 w-4 text-primary rounded">
                            <span class="ml-2 text-sm text-dark-2">记住我</span>
                        </label>
                        <a href="#" class="text-sm text-primary hover:underline">忘记密码？</a>
                    </div>
                    <button type="submit" class="w-full bg-primary text-white py-3 rounded-lg hover:bg-primary/90 transition-colors font-medium">登录</button>
                </form>
                <div class="mt-4 text-center">
                    <span class="text-sm text-dark-2">还没有账号？</span>
                    <a href="register.html" class="text-sm text-primary hover:underline">立即注册</a>
                </div>
                <div class="mt-6">
                    <div class="relative flex items-center">
                        <div class="flex-grow border-t border-light-2"></div>
                        <span class="flex-shrink mx-4 text-sm text-light-3">其他登录方式</span>
                        <div class="flex-grow border-t border-light-2"></div>
                    </div>
                    <div class="flex justify-center space-x-6 mt-4">
                        <a href="#" class="text-dark-2 hover:text-primary transition-colors">
                            <i class="fa fa-weixin text-2xl"></i>
                        </a>
                        <a href="#" class="text-dark-2 hover:text-primary transition-colors">
                            <i class="fa fa-qq text-2xl"></i>
                        </a>
                        <a href="#" class="text-dark-2 hover:text-primary transition-colors">
                            <i class="fa fa-weibo text-2xl"></i>
                        </a>
                    </div>
                </div>
            </div>
        </div>
    </main>

    <!-- 页脚 -->
    <footer class="bg-dark text-white pt-12 pb-6">
        <div class="container mx-auto px-4">
            <div class="grid grid-cols-1 md:grid-cols-4 gap-8 mb-8">
                <div>
                    <h3 class="text-lg font-bold mb-4">关于我们</h3>
                    <ul class="space-y-2">
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">公司简介</a></li>
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">招贤纳士</a></li>
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">联系我们</a></li>
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">隐私政策</a></li>
                    </ul>
                </div>
                <div>
                    <h3 class="text-lg font-bold mb-4">帮助中心</h3>
                    <ul class="space-y-2">
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">购物指南</a></li>
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">支付方式</a></li>
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">配送说明</a></li>
                        <li><a href="#" class="text-light-3 hover:text-white transition-colors">售后服务</a></li>
                    </ul>
                </div>
                <div>
                    <h3 class="text-lg font-bold mb-4">关注我们</h3>
                    <div class="flex space-x-4 mb-4">
                        <a href="#" class="w-10 h-10 rounded-full bg-dark-2 flex items-center justify-center hover:bg-primary transition-colors">
                            <i class="fa fa-weixin"></i>
                        </a>
                        <a href="#" class="w-10 h-10 rounded-full bg-dark-2 flex items-center justify-center hover:bg-primary transition-colors">
                            <i class="fa fa-weibo"></i>
                        </a>
                        <a href="#" class="w-10 h-10 rounded-full bg-dark-2 flex items-center justify-center hover:bg-primary transition-colors">
                            <i class="fa fa-instagram"></i>
                        </a>
                        <a href="#" class="w-10 h-10 rounded-full bg-dark-2 flex items-center justify-center hover:bg-primary transition-colors">
                            <i class="fa fa-youtube-play"></i>
                        </a>
                    </div>
                    <p class="text-light-3">扫描二维码，下载APP</p>
                    <div class="mt-2 bg-white p-1 inline-block rounded">
                        <img src="images/qrcode.jpg" alt="APP下载二维码" class="w-24 h-24">
                    </div>
                </div>
                <div>
                    <h3 class="text-lg font-bold mb-4">联系方式</h3>
                    <ul class="space-y-3">
                        <li class="flex items-start">
                            <i class="fa fa-map-marker mt-1 mr-3 text-primary"></i>
                            <span class="text-light-3">广鸡</span>
                        </li>
                        <li class="flex items-center">
                            <i class="fa fa-phone mr-3 text-primary"></i>
                            <span class="text-light-3">400-888-8888</span>
                        </li>
                        <li class="flex items-center">
                            <i class="fa fa-envelope mr-3 text-primary"></i>
                            <span class="text-light-3">service@shoppingease.com</span>
                        </li>
                        <li class="flex items-center">
                            <i class="fa fa-clock-o mr-3 text-primary"></i>
                            <span class="text-light-3">周一至周日 9:00-22:00</span>
                        </li>
                    </ul>
                </div>
            </div>
            <div class="border-t border-dark-2 pt-6 text-center text-light-3 text-sm">
                <p>© 2025 ShoppingEase 轻松购物平台 版权所有 京ICP备12345678号-1</p>
            </div>
        </div>
    </footer>

    <script src="js/auth.js"></script>
</body>
</html>    